import axios from "../utils/axios";

export function getStocks(type) {
    return axios.get('/stock/' + type)
}

export function getStockHold() {
    return axios.get('/stock/hold')
}

export function getStockInfo(stock) {
    return axios.get('/stock/info/'+stock)
}

export function getFinanceData(stock) {
    return axios.get('/stock/finance/'+stock)
}

export function getTradingRankData(stock) {
    return axios.get('/stock/tradingRank/'+stock)
}

export function getRollStocks(search) {
    if (search)
        return axios.get('/stock/roll?search='+search)
    return axios.get('/stock/roll')
}